package com.woniuxy.house.entity;

import lombok.Data;
import org.springframework.security.core.GrantedAuthority;
import org.springframework.security.core.userdetails.User;

import java.util.Collection;

/**
 * @author baobo
 * @date 2022-08-29-11:50
 */
public class ApiSecurityUser extends User {
	private Integer id;

	public Integer getId() {
		return id;
	}

	public void setId(Integer id) {
		this.id = id;
	}

	public ApiSecurityUser(Integer id,String username, String password, Collection<? extends GrantedAuthority> authorities) {
		super(username, password, authorities);
		this.id=id;
	}

	public ApiSecurityUser(String username, String password, boolean enabled, boolean accountNonExpired, boolean credentialsNonExpired, boolean accountNonLocked, Collection<? extends GrantedAuthority> authorities) {
		super(username, password, enabled, accountNonExpired, credentialsNonExpired, accountNonLocked, authorities);
	}
}
